
#include <cassert>
#include <iostream>
#include <vector>
using namespace std;

int main() {
  vector<int> vec{1, 2, 3, 4, 5};
  vec.resize(0);
  vec.push_back(100);
  cout << vec[0] << endl;

  vector<int> tmp;
  for (int i = 0; i < 10000000; ++i) {
    int cap = tmp.capacity();
    tmp.push_back(i);
    if (cap != tmp.capacity()) {
      cap = tmp.capacity();
      cout << cap << "\n";
    }
  }
  cout << endl;
  return 0;
}